<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/common/taglibs.jsp" %>
   
<div class="pageHeader">
	<form  id="pagerForm" onsubmit="return navTabSearch(this);" action="<#noparse>$</#noparse>{ctx }/${className?lower_case}/list" method="post">
	
	<input type="hidden" name="pageNum" value="1" />
	
	<input type="hidden" name="numPerPage" value="<#noparse>$</#noparse>{pagination.numPerPage}" />
	
	<input type="hidden" name="orderField" value="<#noparse>$</#noparse>{pagination.orderField}" />
	
	<div class="searchBar">
		<table class="searchContent">
			<tr>
				<td>
				<#list records as rec>
				<#if rec.pk !='PRI'>
					${rec.comment}：<input type="text" name="search_LIKE_${rec.field}" value="<#noparse>$</#noparse>{param.search_LIKE_${rec.field} }"/>
				</#if>
				</#list>
				</td>
			</tr>
		</table>
		<div class="subBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button type="submit">检索</button></div></div></li> 
			</ul>
		</div>
	</div>
	</form>
</div>
<div class="pageContent">
	<div class="panelBar">
		<ul class="toolBar">
			
			<#if config.shiroPageAnnotation><shiro:hasPermission name="${className?lower_case}:create"></#if>
			<li><a class="add" href="<#noparse>$</#noparse>{ctx }/${className?lower_case}/create" target="dialog" ><span>添加</span></a></li>
			<#if config.shiroPageAnnotation></shiro:hasPermission></#if>
			
			<#if config.shiroPageAnnotation><shiro:hasPermission name="${className?lower_case}:delete"></#if>
			<li><a class="delete" href="<#noparse>$</#noparse>{ctx }/${className?lower_case}/delete/{${pkFieldInfo.field}_${className?lower_case}}" target="ajaxTodo" title="确定要删除吗?"><span>删除</span></a></li>
			<#if config.shiroPageAnnotation></shiro:hasPermission></#if>
			
			<#if config.shiroPageAnnotation><shiro:hasPermission name="${className?lower_case}:edit"></#if>
			<li><a class="edit" href="<#noparse>$</#noparse>{ctx }/${className?lower_case}/update/{${pkFieldInfo.field}_${className?lower_case}}" target="dialog"><span>修改</span></a></li>
			<#if config.shiroPageAnnotation></shiro:hasPermission></#if>
			
			<li class="line">line</li>
			
			<#if config.shiroPageAnnotation><shiro:hasPermission name="${className?lower_case}:export-xls"></#if>
			<li><a class="icon" href="<#noparse>$</#noparse>{ctx }/${className?lower_case}/export/xls" target="dwzExport" targetType="navTab" title="实要导出这些记录吗?"><span>导出EXCEL</span></a></li>
			<#if config.shiroPageAnnotation></shiro:hasPermission></#if>
			
		</ul>
	</div>
	<table class="table" width="100%" layoutH="138">
		<thead>
			<tr>
				<#list records as rec>
					<th>${rec.comment}</th>
				</#list>
			</tr>
		</thead>
		<tbody>
			<c:forEach items="<#noparse>$</#noparse>{${className?lower_case}s.content }" var="${className?lower_case}">
			<tr target="${pkFieldInfo.field}_${className?lower_case}" rel="<#noparse>$</#noparse>{${className?lower_case}.${pkFieldInfo.field} }">
				<#list records as rec>
				<td><#noparse>$</#noparse>{${className?lower_case}.${rec.field} }</td>
				</#list>
			</tr>
			</c:forEach>
		</tbody>
	</table>
	
	<tags:pagination page="<#noparse>$</#noparse>{${className?lower_case}s}" paginationSize="<#noparse>$</#noparse>{pagination.numPerPage }"/>
	
</div>
